Optimal. Leaf size=103 \[ \frac{(d+e x)^3 \left (a+b \tan ^{-1}(c x)\right )}{3 e}-\frac{b \left (3 c^2 d^2-e^2\right ) \log \left (c^2 x^2+1\right )}{6 c^3}-\frac{b d \left (d^2-\frac{3 e^2}{c^2}\right ) \tan ^{-1}(c x)}{3 e}-\frac{b d e x}{c}-\frac{b e^2 x^2}{6 c} \]
[Out]
________________________________________________________________________________________
Rubi [A] time = 0.0896576, antiderivative size = 103, normalized size of antiderivative = 1., number of steps used = 6, number of rules used = 5, integrand size = 16, \(\frac{\text{number of rules}}{\text{integrand size}}\) = 0.312, Rules used = {4862, 702, 635, 203, 260} \[ \frac{(d+e x)^3 \left (a+b \tan ^{-1}(c x)\right )}{3 e}-\frac{b \left (3 c^2 d^2-e^2\right ) \log \left (c^2 x^2+1\right )}{6 c^3}-\frac{b d \left (d^2-\frac{3 e^2}{c^2}\right ) \tan ^{-1}(c x)}{3 e}-\frac{b d e x}{c}-\frac{b e^2 x^2}{6 c} \]
Antiderivative was successfully verified.
[In]
[Out]
Rule 4862
Rule 702
Rule 635
Rule 203
Rule 260
Rubi steps
\begin{align*} \int (d+e x)^2 \left (a+b \tan ^{-1}(c x)\right ) \, dx &=\frac{(d+e x)^3 \left (a+b \tan ^{-1}(c x)\right )}{3 e}-\frac{(b c) \int \frac{(d+e x)^3}{1+c^2 x^2} \, dx}{3 e}\\ &=\frac{(d+e x)^3 \left (a+b \tan ^{-1}(c x)\right )}{3 e}-\frac{(b c) \int \left (\frac{3 d e^2}{c^2}+\frac{e^3 x}{c^2}+\frac{c^2 d^3-3 d e^2+e \left (3 c^2 d^2-e^2\right ) x}{c^2 \left (1+c^2 x^2\right )}\right ) \, dx}{3 e}\\ &=-\frac{b d e x}{c}-\frac{b e^2 x^2}{6 c}+\frac{(d+e x)^3 \left (a+b \tan ^{-1}(c x)\right )}{3 e}-\frac{b \int \frac{c^2 d^3-3 d e^2+e \left (3 c^2 d^2-e^2\right ) x}{1+c^2 x^2} \, dx}{3 c e}\\ &=-\frac{b d e x}{c}-\frac{b e^2 x^2}{6 c}+\frac{(d+e x)^3 \left (a+b \tan ^{-1}(c x)\right )}{3 e}-\frac{1}{3} \left (b d \left (\frac{c d^2}{e}-\frac{3 e}{c}\right )\right ) \int \frac{1}{1+c^2 x^2} \, dx-\frac{\left (b \left (3 c^2 d^2-e^2\right )\right ) \int \frac{x}{1+c^2 x^2} \, dx}{3 c}\\ &=-\frac{b d e x}{c}-\frac{b e^2 x^2}{6 c}-\frac{b d \left (d^2-\frac{3 e^2}{c^2}\right ) \tan ^{-1}(c x)}{3 e}+\frac{(d+e x)^3 \left (a+b \tan ^{-1}(c x)\right )}{3 e}-\frac{b \left (3 c^2 d^2-e^2\right ) \log \left (1+c^2 x^2\right )}{6 c^3}\\ \end{align*}
Mathematica [A] time = 0.329405, size = 163, normalized size = 1.58 \[ \frac{(d+e x)^3 \left (a+b \tan ^{-1}(c x)\right )-\frac{b \left (\left (c^2 d^2 \left (\sqrt{-c^2} d+3 e\right )-e^2 \left (3 \sqrt{-c^2} d+e\right )\right ) \log \left (1-\sqrt{-c^2} x\right )-\left (c^2 d^2 \left (\sqrt{-c^2} d-3 e\right )+e^2 \left (e-3 \sqrt{-c^2} d\right )\right ) \log \left (\sqrt{-c^2} x+1\right )+c^2 e^2 x (6 d+e x)\right )}{2 c^3}}{3 e} \]
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
Maple [A] time = 0.027, size = 137, normalized size = 1.3 \begin{align*}{\frac{a{e}^{2}{x}^{3}}{3}}+ae{x}^{2}d+ax{d}^{2}+{\frac{a{d}^{3}}{3\,e}}+{\frac{b{e}^{2}\arctan \left ( cx \right ){x}^{3}}{3}}+be\arctan \left ( cx \right ){x}^{2}d+b\arctan \left ( cx \right ) x{d}^{2}-{\frac{b{e}^{2}{x}^{2}}{6\,c}}-{\frac{bedx}{c}}-{\frac{b\ln \left ({c}^{2}{x}^{2}+1 \right ){d}^{2}}{2\,c}}+{\frac{b{e}^{2}\ln \left ({c}^{2}{x}^{2}+1 \right ) }{6\,{c}^{3}}}+{\frac{\arctan \left ( cx \right ) bed}{{c}^{2}}} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Maxima [A] time = 1.46562, size = 170, normalized size = 1.65 \begin{align*} \frac{1}{3} \, a e^{2} x^{3} + a d e x^{2} +{\left (x^{2} \arctan \left (c x\right ) - c{\left (\frac{x}{c^{2}} - \frac{\arctan \left (c x\right )}{c^{3}}\right )}\right )} b d e + \frac{1}{6} \,{\left (2 \, x^{3} \arctan \left (c x\right ) - c{\left (\frac{x^{2}}{c^{2}} - \frac{\log \left (c^{2} x^{2} + 1\right )}{c^{4}}\right )}\right )} b e^{2} + a d^{2} x + \frac{{\left (2 \, c x \arctan \left (c x\right ) - \log \left (c^{2} x^{2} + 1\right )\right )} b d^{2}}{2 \, c} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Fricas [A] time = 2.30074, size = 281, normalized size = 2.73 \begin{align*} \frac{2 \, a c^{3} e^{2} x^{3} +{\left (6 \, a c^{3} d e - b c^{2} e^{2}\right )} x^{2} + 6 \,{\left (a c^{3} d^{2} - b c^{2} d e\right )} x + 2 \,{\left (b c^{3} e^{2} x^{3} + 3 \, b c^{3} d e x^{2} + 3 \, b c^{3} d^{2} x + 3 \, b c d e\right )} \arctan \left (c x\right ) -{\left (3 \, b c^{2} d^{2} - b e^{2}\right )} \log \left (c^{2} x^{2} + 1\right )}{6 \, c^{3}} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Sympy [A] time = 1.31008, size = 160, normalized size = 1.55 \begin{align*} \begin{cases} a d^{2} x + a d e x^{2} + \frac{a e^{2} x^{3}}{3} + b d^{2} x \operatorname{atan}{\left (c x \right )} + b d e x^{2} \operatorname{atan}{\left (c x \right )} + \frac{b e^{2} x^{3} \operatorname{atan}{\left (c x \right )}}{3} - \frac{b d^{2} \log{\left (x^{2} + \frac{1}{c^{2}} \right )}}{2 c} - \frac{b d e x}{c} - \frac{b e^{2} x^{2}}{6 c} + \frac{b d e \operatorname{atan}{\left (c x \right )}}{c^{2}} + \frac{b e^{2} \log{\left (x^{2} + \frac{1}{c^{2}} \right )}}{6 c^{3}} & \text{for}\: c \neq 0 \\a \left (d^{2} x + d e x^{2} + \frac{e^{2} x^{3}}{3}\right ) & \text{otherwise} \end{cases} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Giac [A] time = 1.13929, size = 217, normalized size = 2.11 \begin{align*} \frac{2 \, b c^{3} x^{3} \arctan \left (c x\right ) e^{2} + 6 \, b c^{3} d x^{2} \arctan \left (c x\right ) e + 6 \, b c^{3} d^{2} x \arctan \left (c x\right ) + 2 \, a c^{3} x^{3} e^{2} + 6 \, a c^{3} d x^{2} e + 6 \, a c^{3} d^{2} x - 6 \, \pi b c d e \mathrm{sgn}\left (c\right ) \mathrm{sgn}\left (x\right ) - b c^{2} x^{2} e^{2} - 6 \, b c^{2} d x e - 3 \, b c^{2} d^{2} \log \left (c^{2} x^{2} + 1\right ) + 6 \, b c d \arctan \left (c x\right ) e + b e^{2} \log \left (c^{2} x^{2} + 1\right )}{6 \, c^{3}} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]